package utils;

import java.io.File;

/**
 * Created by violorch on 2016/3/25.
 */
public class TmpBaseUtil {
    public static boolean createFile(String parentPath, String targetPath) {
        try {
            File dir = new File(parentPath);
            if (!dir.exists()) {
                dir.mkdirs();
            }

            File file = new File(targetPath);
            if (!file.exists()) {
                file.createNewFile();
            }
            return true;
        } catch (Exception e) {
            e.printStackTrace();
            return false;
        }
    }
}
